<#import "Common.ftl" as zbsgc>
<%@ page language="java" pageEncoding="UTF-8"%>
<%@ include file="/common/inc.jsp" %>
<page:header title="修改页面">
<script lang="JavaScript">
<%-- 返回操作 --%>
function back(){
	window.location.href = "<@zbsgc.escape text="base"/>/${methodMeta.listUrl}";
}
<%-- 修改操作 --%>
function update${beanMeta.clazzName}(){
	 var saveOp = new AjaxFormOp();
	 saveOp.form=document.update${beanMeta.clazzName}Form;
	 saveOp.opName='保存';
	 saveOp.beforeSubmit=function(a,f,o){
	}
	saveOp.success=function(data){
    	if(data.flag){
    		alert(data.msg);
    		back();
    	}else{
    		alert(data.msg);
    	}
	};
	saveOp.execute();
}
</script>

</page:header>
<%-- 头部 --%>
<div class="location"><span><d:path/></span></div>
<form action="<@zbsgc.escape text="base"/>/${methodMeta.updateUrl}" name="update${beanMeta.clazzName}Form" id="update${beanMeta.clazzName}Form" method="post" >
   	<input type="hidden" id="id" name="${beanMeta.entityName}.id" value="${r"$"}${r"{"}${beanMeta.entityName}.${beanMeta.idField.fieldName}${r"}"}" >
    <table cellspacing="0" cellpadding="0" border="0" width="98.2%" class="detailList">
      	<@zbsgcFieldContent update="true"/>
	</table>
</form>
<br/>	
 <div align="center">
    <input type="button" icon="save" value="保存" onclick="update${beanMeta.clazzName}();"/>
    <input type="button" icon="cancel" value="返回" onclick="back()"/>
 </div>
<%-- 底部 --%>
<d:sysHelper/>
<script lang="JavaScript">
	autoStyle(null,{select:false,radio:false});
</script>
<page:footer></page:footer>
